import { createRouter, createWebHashHistory } from 'vue-router'
import Login from '../views/login/Login.vue'
import Main from '../views/home/Main.vue'
import Personal from '../views/personal.vue'
import Market from '../views/scriptMarket/market.vue'
import Chat from '../views/chat/chat.vue'
import Chat2 from '../views/chat/chat2.vue'


const routes = [
  {
    path: '/',
    redirect: '/login'
  },
  {
    path: '/login',
    name: 'login',
    component: Login
  },
  {
    path: '/main',
    name: 'main',
    component: Main
  },
  {
    path: '/personal',
    name: 'personal',
    component: Personal
  },
  {
    path: '/market',
    name: 'market',
    component: Market
  },
  {
    path: '/chat',
    name: 'chat',
    component: Chat
  },
  {
    path: '/chat2',
    name: 'chat2',
    component: Chat2
  },
]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router
